/* eslint-disable */
import request from "@/utils/request";
import { buildURLWithParams } from "@/utils";

export const ceshiApi_visitor_login = () =>
  request.post(`visitor/login?flag=false&username=1123@qq.com&password=123456`);

export const visitor_logout = () => request.get(`visitor/logout`);

export const visitor_register = () =>
  request.post(`visitor/register`, {
    email: "1123@qq.com",
    password: "123456",
    name: "gang03",
  });
export const visitor_page = () => request.get(`visitor/page`);
export const visitor_updata = () => request.post(`visitor/update`);
export const visitor_detele = () =>
  request.post(`visitor/delete`, [1712309372783]);
export const visitor_add = () =>
  request.post(`visitor/add`, {
    account: "v0004",
    password: "123456",
    name: "zhong1",
    sex: "男",
    email: "333@qq.com",
    phoneNum: "13466667777",
  });

export const rate_add = () =>
  request.post(`rate/add`, {
    visitorName: "钟港城",
    recordId: "1",
    message: "laji",
    score: "1",
  });
export const rate_update = () =>
  request.post(`rate/update`, {
    id: 1712305582285,
    visitorName: "zgc666",
    score: "5",
    message: "大大滴呦西",
  });
export const rate_delete = () =>
  request.post(`rate/delete`, [1712306220686, 1712306221395]);
export const rate_page = () => request.get(`rate/page?recordId=2`);
export const place_add = () =>
  request.post(`place/add`, {
    name: "zhong1",
    container: "500",
    description: "5",
    status: "关闭",
  });
export const place_update = () =>
  request.post(`place/update`, {
    id: 1712311612234,
    name: "zhong2",
    container: "50",
    description: "hahhah",
    status: "维护中",
  });
export const place_delete = () => request.post(`place/delete`, [1712311636481]);
export const place_page = () => request.get(`place/page`);

export const gate_add = () =>
  request.post(`gate/add`, {
    name: "东门",
    type: "主校门",
    description: "位于校园东面",
    status: "关闭",
  });
export const gate_update = () =>
  request.post(`gate/update`, {
    id: 1712325080668,
    name: "西门",
    type: "小校门",
    description: "位于校园西面",
    status: "开放",
  });
export const gate_delete = () =>
  request.post(`gate/delete`, [1712325080539, 1712325080415]);
export const gate_page = () => request.get(`gate/page?status=开放`);

export const send_email = () =>
  request.post(`email/sendEmail`, {
    to: "986042289@qq.com",
    subject: "hello",
    content: "你好，这是一封邮件！！",
  });

// 获取用户信息
// export const getUserInfo = () => {
//   return request("/user/currentUser");
// };

export const recommend_add = () =>
  request.post(`recommend/add`, {
    name: "原神1",
    phoneNum: "12345667777",
    email: "777@qq.com",
    def: "是",
    visitor_id: "f0001",
    visitor_name: "张三",
  });
export const recommend_update = () =>
  request.post(`recommend/update`, {
    id: "1712381730087",
    name: "原神QIDONG",
    phoneNum: "12345667777",
    email: "777@qq.com",
    def: "是",
    visitorId: "f0001",
    visitorName: "张三",
  });
export const recommend_delete = () =>
  request.post(`recommend/delete`, [1712381730087]);
export const recommend_page = () =>
  request.get(`recommend/page?visitorName=张三`);

export const address_add = () =>
  request.post(`address/add`, {
    country: "原神1",
    city: "12345667777",
    detail: "777@qq.com",
    visitorId: "f0001",
    visitorName: "张三",
  });
export const address_update = () =>
  request.post(`address/update`, {
    id: "1712384619007",
    country: "原神21",
    city: "12345667777",
    detail: "777@qq.com",
    visitorId: "f0001",
    visitorName: "张三",
  });
export const address_delete = () =>
  request.post(`address/delete`, [1712381730087]);
export const address_page = () => request.get(`address/page`);

export const car_add = () =>
  request.post(`car/add`, {
    num: "原神wwww1",
    brand: "12345667777",
    type: "777@qq.com",
    color: "",
    visitorId: "f0001",
    visitorName: "张三",
  });
export const car_update = () =>
  request.post(`car/update`, {
    id: "1712386965089",
    num: "原dddd神1",
    brand: "12345667777",
    type: "777@qq.com",
    color: "",
    visitorId: "f0001",
    visitorName: "张三",
  });
export const car_delete = () => request.post(`car/delete`, [1712386965224]);
export const car_page = () => request.get(`car/page`);

export const comment_add = () =>
  request.post(`comment/add`, {
    newsId: "1111",
    newsTitle: "2222",
    newsContent: "3333",
    content: "哈哈哈哈",
    visitorId: "6666",
    visitorName: "我超，原批！",
  });
export const comment_update = () =>
  request.post(`comment/update`, {
    id: "1712405757003",
    newsId: "1111",
    newsTitle: "2222",
    newsContent: "3333",
    content: "哈哈哈哈",
    visitorId: "6666",
    visitorName: "我超，原批！",
  });
export const comment_delete = () =>
  request.post(`comment/delete`, [1712405801608, 1712405757003]);
export const comment_page = () => request.get(`comment/page?visitorId=7777`);

export const loveTotal_add = () =>
  request.post(`loveTotal/add`, {
    newsId: "1111",
    newsTitle: "2222",
    newsFenlei: "1",
    newsImg: "haha",
    newsFrom: "oo",
    newsTime: "2020",
    newsContent: "shabi",
    visitorId: "0001",
    visitorName: "王二",
  });
export const loveTotal_update = () =>
  request.post(`loveTotal/update`, {
    id: "1712407085629",
    newsId: "1111",
    newsTitle: "2222",
    newsFenlei: "1",
    newsImg: "haha",
    newsFrom: "oo",
    newsTime: "2020",
    newsContent: "shabi",
    visitorId: "0001",
    visitorName: "门酱",
  });
export const loveTotal_delete = () =>
  request.post(`loveTotal/delete`, [1712407117734]);
export const loveTotal_page = () =>
  request.get(`loveTotal/page?visitorId=0002`);

export const loveCount_add = () =>
  request.post(`loveCount/add`, {
    newsId: "1",
    count: 200,
  });
export const loveCount_update = () =>
  request.post(`loveCount/update`, {
    id: "1712411125885",
    newsId: "1",
    count: 201,
  });
export const loveCount_delete = () =>
  request.post(`loveCount/delete`, [1712411126015]);
export const loveCount_page = () => request.get(`loveCount/page`);

export const starCount_add = () =>
  request.post(`starCount/add`, {
    newsId: "1",
    count: 500,
  });
export const starCount_update = () =>
  request.post(`starCount/update`, {
    id: "1712411914288",
    newsId: "1",
    count: 501,
  });
export const starCount_delete = () =>
  request.post(`starCount/delete`, [1712411914156]);
export const starCount_page = () => request.get(`starCount/page`);

export const starTotal_add = () =>
  request.post(`starTotal/add`, {
    newsId: "9999",
    newsTitle: "star",
    newsFenlei: "2",
    newsImg: "wuwuwu",
    newsFrom: "xx",
    newsTime: "2024",
    newsContent: "laotan",
    visitorId: "0002",
    visitorName: "詹姆斯",
  });
export const starTotal_update = () =>
  request.post(`starTotal/update`, {
    id: "1712412784387",
    newsId: "9999",
    newsTitle: "star",
    newsFenlei: "2",
    newsImg: "wuwuwu",
    newsFrom: "xx",
    newsTime: "2024",
    newsContent: "laotan",
    visitorId: "0003",
    visitorName: "也中",
  });
export const starTotal_delete = () =>
  request.post(`starTotal/delete`, [1712412783940]);
export const starTotal_page = () =>
  request.get(`starTotal/page?visitorName=也中`);

export const verificationCode_add = () =>
  request.post(`verificationCode/add`, {
    from: 'hahah',
    to: 'xixixi',
    subject: 'niubi',
    content: 'lalalalallalalalalalala'
  });
export const verificationCode_update = () =>
  request.post(`verificationCode/update`, {
    id: "1712493995027",
    from: "hahah",
    to: "xixixi",
    subject: "niubi",
    content: "基尼太美",
  });
export const verificationCode_delete = () =>
  request.post(`verificationCode/delete`, [1712494033012]);
export const verificationCode_page = () =>
  request.get(`verificationCode/page?content=基尼太美`);

export const tips_add = () =>
  request.post(`tips/add`, {
    from: "666",
    to: "999",
    subject: "youxi",
    content: "wochao!!",
  });
export const tips_update = () =>
  request.post(`tips/update`, {
    id: "1712494738753",
    from: "666",
    to: "999",
    subject: "youxi",
    content: "gaiya!!!!",
  });
export const tips_delete = () => request.post(`tips/delete`, [1712494736432]);
export const tips_page = () => request.get(`tips/page?subject=youbo`);

export const appeal_add = () =>
  request.post(`appeal/add`, {
    blacklistId: "666",
    visitorId: '0001',
    blacklistReason: '太丑',
    blacklistTime: '99:99',
    content: 'niubi!'
  });
export const appeal_update = () =>
  request.post(`appeal/update`, {
    id: "1712496561235",
    blacklistId: "666",
    visitorId: "0001",
    blacklistReason: "太帅",
    blacklistTime: "99:99",
    content: "niubi!",
  });
export const appeal_delete = () =>
  request.post(`appeal/delete`, [1712496560040, 1712496561100, 1712496560785]);
export const appeal_page = () => request.get(`appeal/page`);
